#ifndef MAINWINDOW_H
#define MAINWINDOW_H

#include "webcommunication.h"

#include <QMainWindow>
#include <QtWebChannel>

QT_BEGIN_NAMESPACE
namespace Ui {
class MainWindow;
}
QT_END_NAMESPACE

class MainWindow : public QMainWindow
{
    Q_OBJECT

public:
    MainWindow(QWidget *parent = nullptr);
    ~MainWindow();

private:
    void LoadMap(const QString& mapFile);

private slots:
    void on_comboBoxMapsType_currentTextChanged(const QString &maptype);

    void on_PositionBtn_clicked();
    void setAddressDescription();
    void setCurLocationInfo();
    void on_queryRouteBtn_clicked();

    void on_addOverlayBtn_clicked();

    void on_clearOverlayBtn_clicked();

    void on_mapsTypeCheckBox_stateChanged();

    void on_zoomScaleCheckBox_stateChanged();

    void on_comboBoxTravelMode_currentTextChanged(const QString &arg1);

private:
    Ui::MainWindow *ui;
    WebCommunication *webcom;
    QString m_travelMode = "walking";
    QWebChannel *webChannel = nullptr;
};
#endif // MAINWINDOW_H
